package com.biz.primus.ms.order.convertor;

import com.biz.primus.model.order.vo.OrderConsigneeInfoVO;
import com.biz.primus.ms.order.dao.po.embeddable.OrderConsigneeInfo;
import org.codelogger.utils.BeanUtils;

/**
 * 收货信息转换器
 *
 * @author Tiger Feng
 * @date 2017年11月03日
 */
public class OrderConsigneeInfoConvertor {
    public static OrderConsigneeInfo vo2PO(OrderConsigneeInfoVO vo){
        if(vo == null){
            return null;
        }
        OrderConsigneeInfo po = new OrderConsigneeInfo();
        BeanUtils.copyProperties(vo, po);
        return po;
    }

    public static OrderConsigneeInfoVO po2VO(OrderConsigneeInfo po){
        if(po == null){
            return null;
        }
        OrderConsigneeInfoVO vo = new OrderConsigneeInfoVO();
        BeanUtils.copyProperties(po, vo);
        return vo;
    }
}
